<template>
    <div id='' class='operation_content'>
        <i-table class="table_content" ref="myTable" :search="getSearch" :table="getTbale" :pageConfig="pageConfig" @resetTable="ResetTable">
            <template slot-scope="{ dataS }" slot="status">
                <Tag v-if="dataS.status == 1" color="success">成功</Tag>
                <Tag v-else color="warning">失败</Tag>
            </template>
            <template slot-scope="{ dataS }" slot="operation">
                <Tag v-if="dataS.operation == 0" color="success">用户登录</Tag>
                <Tag v-else color="warning">用户退出</Tag>
            </template>
        </i-table>
    </div>
</template>
<script>
import { operationLogConfig } from './table_config'
export default {
    name: '',
    props: [''],
    data() {
        return {
            search: {},
            tableConfig: {},
            pageConfig: operationLogConfig.page // 翻页器配置
        };
    },
    components: {},
    computed: {
        getSearch() {
            this.search = icu.util.deepClone(operationLogConfig.search);// 为不改变原始配置数据，进行深度克隆。
            return this.search;
        },
        getTbale() {
            this.tableConfig = icu.util.deepClone(operationLogConfig.table); // 深度克隆表格配置。
            this.tableConfig.event = {}
            return this.tableConfig;
        }
    },
    beforeMount() { },
    mounted() { },
    methods: {
        ResetTable() { }
    },
    watch: {}
}
</script>
<style lang='less' scoped>
.operation_content {
    background-color: #fff;
    padding: 0 20px;
    width: 100%;
    height: 800px;
    .table_content {
        height: 752px;
        overflow: auto;
    }
}
</style>